The present invention concerns a method for the bidirectional, serial transmission of data between two devices by way of a single electric transmission line. The invention further concerns a corresponding transmission system and corresponding devices.
During the development, production or maintenance of electronic devices it may be necessary to be able to access the firmware and/or internal states of the device to be tested, in reading and/or writing mode. One example would be interrogating a battery module in accordance with charge state, serial number, an identification code or similar items of information. A further example would be the configuration of internal parameters in an A/D converter component. In that respect for cost reasons it is not desirable in many cases to provide a dedicated interface hardware for communication with a testing device, in the device to be tested. What would be desirable would be the possibility of generic data exchange with total elimination of specific interface hardware and with only low demands in terms of computing time and timing of the device to be tested.
A preferred option is to serially communicate with the device to be tested, by way of a single controller pin which can otherwise also be used for other uses, for example for implementing a switching key. The memory and computing capacity necessary for implementing such a communication and for synchronization of the data exchange, in the device to be tested, should preferably be as small as possible.
Methods and systems for the serial transmission of data between two or more devices are known. The one-wire bus developed by Dallas Semiconductor (referred to as the “1-wire”) describes a bidirectional serial interface for data transmission by way of a single electric line.
The one-wire bus can be used in networks with a master device and one or more slave devices, in which case it is possible to construct different network topologies. As the one-wire bus does not use a separate electric line for the clock signal, clock and data must be transmitted by way of the same electric line. That is effected by the master device initiating a cycle for writing or reading a single bit so that it firstly pulls the voltage on the electric line (the so-called HI-voltage) downwardly, that is to say to the so-called LO-voltage.
In the writing mode the master device, for writing a binary “1”, retains the LO-voltage for a predetermined time tWRITE-1 before it releases the electric line again to the HI-voltage. To write a binary “0” the master device already releases the electric line to the HI-voltage again after a predetermined time tWRITE-0 which is shorter than tWRITE-1. A reading slave device registers the falling edge of the voltage pulse generated by the master device and after a predetermined delay time tSAMPLE-S which is suitably between tWRITE-0 and tWRITE-1 reads the voltage on the electric line. If the voltage read by the slave device corresponds to the HI-voltage a binary “0” was recognized, while if the read voltage corresponds to the LO-voltage a binary “1” was recognized.
In the reading mode the master device releases the electric line to the HI-voltage again after a predetermined time tREAD. A writing slave device registers the falling edge of the voltage pulse generated by the master device and to write a binary “0” after the predetermined time tREAD pulls the voltage on the electric line to the LO-voltage. To write a binary “1” a writing slave device does nothing at all so that the HI-voltage is again on the electric line. After a predetermined delay time tSAMPLE-M which is greater than tREAD the master reads the voltage on the electric line. If the voltage read by the master device corresponds to the HI-voltage a binary “0” was recognized while if the read voltage corresponds to the LO-voltage a binary “1” was recognized. The one-wire bus has the disadvantage that the slave devices require dedicated hardware (delay member and so forth) and must be synchronized to the timing predetermined by the master device. In the slave devices that leads to a comparatively high resource requirement for synchronization.
A further known serial bus system is the I2C system developed by Philips Semiconductors, which is used to connect slow peripheral devices to the main circuit board of a computer, to an embedded system, to a cellular telephone or to a similar device. The I2C system has the disadvantage that it needs two separate electric lines for transmission of clock and data.
A similar system is the SPI-bus (from “Serial Peripheral Interface”) developed by Motorola which permits synchronous serial transmission of data between a master device and one or more slave devices. The SPI-bus however has the disadvantage that it uses a total of four separate electric lines for the transmission of clock and data.
Thus the object of the present invention is to provide a method for bidirectional serial transmission of data between two devices, in particular between a device to be tested and a testing device, which uses only a single electric transmission line for the transmission of clock and data and which involves a lower need for resources for synchronization than the previously known transmission systems.